package com.surenpi.jenkins.client.core;

import com.surenpi.jenkins.client.BaseModel;

public class Cause extends BaseModel {
   private String userId;
   private String userName;
   private String shortDescription;

   public String getUserId() {
      return this.userId;
   }

   public String getUserName() {
      return this.userName;
   }

   public String getShortDescription() {
      return this.shortDescription;
   }

   public void setUserId(final String userId) {
      this.userId = userId;
   }

   public void setUserName(final String userName) {
      this.userName = userName;
   }

   public void setShortDescription(final String shortDescription) {
      this.shortDescription = shortDescription;
   }

   public boolean equals(final Object o) {
      if (o == this) {
         return true;
      } else if (!(o instanceof Cause)) {
         return false;
      } else {
         Cause other = (Cause)o;
         if (!other.canEqual(this)) {
            return false;
         } else {
            Object this$userId = this.getUserId();
            Object other$userId = other.getUserId();
            if (this$userId == null) {
               if (other$userId != null) {
                  return false;
               }
            } else if (!this$userId.equals(other$userId)) {
               return false;
            }

            Object this$userName = this.getUserName();
            Object other$userName = other.getUserName();
            if (this$userName == null) {
               if (other$userName != null) {
                  return false;
               }
            } else if (!this$userName.equals(other$userName)) {
               return false;
            }

            Object this$shortDescription = this.getShortDescription();
            Object other$shortDescription = other.getShortDescription();
            if (this$shortDescription == null) {
               if (other$shortDescription != null) {
                  return false;
               }
            } else if (!this$shortDescription.equals(other$shortDescription)) {
               return false;
            }

            return true;
         }
      }
   }

   protected boolean canEqual(final Object other) {
      return other instanceof Cause;
   }

   public int hashCode() {
      int PRIME = 59;
      int result = 1;
      Object $userId = this.getUserId();
      result = result * 59 + ($userId == null ? 43 : $userId.hashCode());
      Object $userName = this.getUserName();
      result = result * 59 + ($userName == null ? 43 : $userName.hashCode());
      Object $shortDescription = this.getShortDescription();
      result = result * 59 + ($shortDescription == null ? 43 : $shortDescription.hashCode());
      return result;
   }

   public String toString() {
      return "Cause(userId=" + this.getUserId() + ", userName=" + this.getUserName() + ", shortDescription=" + this.getShortDescription() + ")";
   }
}
